<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<link rel="stylesheet"
	href="${pageContext.request.contextPath}/css/adduser.css">
<script src="${pageContext.request.contextPath}/js/adduser.js"></script>
<script>
	var flag = '${flag}'
	if (flag == '1') {
		alert('添加成功');
	} else if (flag == '2') {
		alert('添加失败');
	} else if (flag == '3') {
		alert('用户名存在');
	}
</script>
<div class="adduser">
	<form action="adduser?action=add" method="post">
		<h1>添加用户</h1>
		<table>
			<tr>
				<th>姓名:</th>
				<td><input autocomplete="off" type="text" name="name"
					class="name"></td>

			</tr>
			<tr>
				<th>性别:</th>
				<td>
					<div class="man">
						<label>男</label for="man"><input type="radio" name="sex" value="0" id="man"
							checked>
					</div>
					<div class="woman">
						<label>女</label for="woman"><input type="radio" name="sex" value="1"
							id="woman">
					</div>
				</td>
			</tr>
			<tr>
				<th>年龄:</th>
				<td><input autocomplete="off" type="text" name="age"
					class="age"><span>岁</span></td>
			</tr>
			<tr>
				<th>用户名:</th>
				<td><input autocomplete="off" type="text" name="username"
					class="username"></td>
			</tr>
			<tr>
				<th>邮箱:</th>
				<td><input autocomplete="off" type="text" name="email"
					class="email"></td>
			</tr>
		</table>
		<span class="error"></span>
		<div class="button">
			<input type="button" value="提交"> <input type="reset"
				value="重置">
		</div>
	</form>
</div>